package top.revery.api.api.user;

import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import top.revery.api.config.UserPageData;
import top.revery.api.entity.user.BaseUserKol;

import java.util.Map;

/**
 * @author denghao
 * @title 网红
 * @package
 * @date 2019/12/13 11:35
 */
@RequestMapping("/api_userKol")
public interface IUserKolApi {

    //分页多条件查询所有
    @PostMapping("/getList")
    UserPageData getList(@RequestParam(value = "pageNum") int pageNum, @RequestParam(value = "pageSize")int pageSize,
                         @RequestBody Map map);

    //保存网红
    @PostMapping("/save")
    BaseUserKol save(@RequestBody BaseUserKol baseUserKol);


    //修改网红
    @PostMapping("/update")
    void update(@RequestBody BaseUserKol baseUserKol,@RequestParam(value = "id") Long id) throws Exception;

    //根据id查询
    @PostMapping("/findById")
    BaseUserKol findById(@RequestParam(value = "id") Long id);
}
